﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using DevComponents.DotNetBar;
using DTO;
using BUS;

namespace NHA_HANG_BUFFET
{
    public partial class frmThuNganCapTheKhachHang : Office2007Form
    {
        public frmThuNganCapTheKhachHang()
        {
            InitializeComponent();
        }

        private int manv;

        public int Manv
        {
            get { return manv; }
            set { manv = value; }
        }

        TheKhachHang tkh = new TheKhachHang();
        TheKhachHangB busTkh = new TheKhachHangB();

        private void btnCapThe_Click(object sender, EventArgs e)
        {
            tkh.TenKh = txtTenKH.Text;
            tkh.CMND = txtCMND.Text;
            tkh.Diemtichluy = 20;
            tkh.Diachi = txtDiaChi.Text;
            tkh.Sodienthoai = txtSoDienThoai.Text;
            if (busTkh.bCapTheKhachHang(tkh, manv))
            {
                MessageBox.Show("Cấp thẻ khách hàng thành công.");
                this.Close();
            }
        }
    }
}
